package com.classtest.DemoExpend.service.Impl;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.classtest.DemoExpend.bean.DbOrder;
import com.classtest.DemoExpend.dao.DbOrderDao;
import com.classtest.DemoExpend.service.DbOrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class DbOrderServiceImpl extends ServiceImpl<DbOrderDao, DbOrder> implements DbOrderService {

    @Autowired
    DbOrderDao dbOrderDao;

    @Override
    public List<DbOrder> getOrderCount(String json){
        return dbOrderDao.getOrderCount(JSONObject.parseObject(json,DbOrder.class));
    }
    public void  updateCourierNum(String json){
        dbOrderDao.updateCourierNum(JSONObject.parseObject(json,DbOrder.class));
    }
}
